import { createStore } from 'vuex'

export default createStore({
    state: {
        user: [{}],
        iphone: ''
    },
    mutations: {
        storageUser(state, user) {
            state.user = user;
        },
        storageiphone(state, iphone) {
            state.iphone = iphone;
        },
        updateUser(state) {
            // state.user =null;
            state.user = [{}];
            state.iphone = ''
        }

    },
    actions: {},
    modules: {},
    getters: {
        getUser(state) {
            return state.user;
        }
    }
})